package com.fqgj.xjd.user.dao;

import com.fqgj.common.api.Page;
import com.fqgj.common.base.BaseMapper;
import com.fqgj.xjd.user.entity.UserBehaviorDeviceShumeiEntity;

import java.util.Date;
import java.util.List;
import java.util.Map;

/**
 * User: zhangxingyun
 * Date: 2017-07-23
 * Time: 14:10:48.127
 */

public interface UserBehaviorDeviceShumeiDao extends BaseMapper<UserBehaviorDeviceShumeiEntity> {

    UserBehaviorDeviceShumeiEntity selectByUserCode(String userCode);

    List<UserBehaviorDeviceShumeiEntity> selectLatestByUserCodes(List<String> userCodes);

    List<UserBehaviorDeviceShumeiEntity> selectListByPage(Date endDate, Page page);

    /**
     * 分页查询
     */
    List<UserBehaviorDeviceShumeiEntity> selectByPage(Map<String, Object> map);

    /**
     * 统计总数
     */
    Integer countAllEntities();

    /**
     * 批量更新
     *
     * @param entities
     */
    void batchUpdate(List<UserBehaviorDeviceShumeiEntity> entities);


    List<UserBehaviorDeviceShumeiEntity> selectNeedParseAppListDateByPage(long startId, int page);
}